package cn.itcast.hotel.web;

import cn.itcast.hotel.pojo.PageResult;
import cn.itcast.hotel.pojo.RequestParams;
import cn.itcast.hotel.service.IHotelService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("/hotel")
public class HotelController {
    @Autowired
    private IHotelService service;
    @PostMapping("/list")
    public PageResult search(@RequestBody RequestParams params){

        return service.search(params);
    }
//    @PostMapping("/filters")
//    public PageResult filters(@RequestBody RequestParams params){
//
//        return service.search(params);
//    }
}
